package com.sharemarking.wa.platform.dto.orderCommon;

import com.fasterxml.jackson.annotation.JsonIgnore;
import com.sharemarking.wa.common.eum.OrderOperateTypeEum;


import java.util.Date;
import java.util.List;

/**
 * @author dxy
 */
public class OrderListDto {
    @JsonIgnore
    private Integer id;
    @JsonIgnore
    private Integer parentId;
    @JsonIgnore
    private Integer payer;
    @JsonIgnore
    private Integer sendOrgId;
    private String code;
    private List<WasteListDto> wasteList;
    private List<OrderOperateTypeEum> operate;
    private String orgName;
    private Integer distance;
    private String loadingAddress;
    private String unLoadingAddress;
    private Integer state;
    private Integer type;
    private String wasteListName;
    private Date arrivalTime;
    private Integer transportFees;
    private String DriverName;
    private Date actualTransferTime;
    private Integer isUrgent;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public Integer getParentId() {
        return parentId;
    }

    public void setParentId(Integer parentId) {
        this.parentId = parentId;
    }

    public Integer getPayer() {
        return payer;
    }

    public void setPayer(Integer payer) {
        this.payer = payer;
    }

    public Integer getState() {
        return state;
    }

    public void setState(Integer state) {
        this.state = state;
    }

    public Integer getSendOrgId() {
        return sendOrgId;
    }

    public void setSendOrgId(Integer sendOrgId) {
        this.sendOrgId = sendOrgId;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }


    public List<OrderOperateTypeEum> getOperate() {
        return operate;
    }

    public void setOperate(List<OrderOperateTypeEum> operate) {
        this.operate = operate;
    }

    public String getOrgName() {
        return orgName;
    }

    public void setOrgName(String orgName) {
        this.orgName = orgName;
    }

    public Integer getDistance() {
        return distance;
    }

    public void setDistance(Integer distance) {
        this.distance = distance;
    }

    public String getLoadingAddress() {
        return loadingAddress;
    }

    public void setLoadingAddress(String loadingAddress) {
        this.loadingAddress = loadingAddress;
    }

    public String getUnLoadingAddress() {
        return unLoadingAddress;
    }

    public void setUnLoadingAddress(String unLoadingAddress) {
        this.unLoadingAddress = unLoadingAddress;
    }

    public List<WasteListDto> getWasteList() {
        return wasteList;
    }

    public void setWasteList(List<WasteListDto> wasteList) {
        this.wasteList = wasteList;
    }

    public String getWasteListName() {
        return wasteListName;
    }

    public void setWasteListName(String wasteListName) {
        this.wasteListName = wasteListName;
    }

    public Integer getIsUrgent() {
        return isUrgent;
    }

    public void setIsUrgent(Integer isUrgent) {
        this.isUrgent = isUrgent;
    }

    public Long getArrivalTime() {
        if (arrivalTime != null) {
            return arrivalTime.getTime();
        }
        return null;
    }

    public void setArrivalTime(Date arrivalTime) {
        this.arrivalTime = arrivalTime;
    }

    public Double getTransportFees() {
        if (transportFees != null) {
            return transportFees * 0.01;
        }
        return null;
    }

    public void setTransportFees(Integer transportFees) {
        this.transportFees = transportFees;
    }

    public String getDriverName() {
        return DriverName;
    }

    public void setDriverName(String driverName) {
        DriverName = driverName;
    }

    public Long getActualTransferTime() {
        if (actualTransferTime!=null){
            return actualTransferTime.getTime();
        }
        return null;
    }

    public void setActualTransferTime(Date actualTransferTime) {
        this.actualTransferTime = actualTransferTime;
    }
}
